# Group Change Password

This Groups APIs are used for change password request of the user.

## Change Password [/v1/auth/change-password]

### Change password using old password [POST]

+ Request

    + Headers

            Content-Type: application/json
            Authorization: JWT <Auth Key>

    + Body

            {
                "data": {
                    "old-password": "fossasia",
                    "new-password": "eventyay"
                }
            }

+ Response 200 (application/json)

            {
              "email": "example@example.com",
              "id": "1",
              "name": "example",
              "password-changed": true
            }

## Reset Forgotten Password [/v1/auth/reset-password]
Change password through token received via email.

### Get Reset Password Token [POST]
Sends the token to reset the account associated with the provided email id via email.
+ Request

    + Headers

            Content-Type: application/json

    + Body

            {
                "data": {
                    "email": "open_event_test_user@fossasia.org"
                }
            }

+ Response 200 (application/json)

        {
          "message": "Email Sent"
        }


### Reset Password from Token [PATCH]

+ Request

    + Headers

            Content-Type: application/json

    + Body

            {
                "data": {
                    "token": "token",
                    "password": "new password"
                }
            }

+ Response 200 (application/json)

        {
              "id": "1",
              "email": "example@example.com",
              "name": "John Doe"
        }
